/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package documenteditor.entidade.model;

import javax.persistence.Column;
import javax.persistence.DiscriminatorValue;
import javax.persistence.Entity;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;

/**
 *
 * @author gleidson.moura
 */
@Entity
@DiscriminatorValue(value = "J")
@NamedQueries({@NamedQuery(name = "Cliente.findByRazaoSocial", query = "SELECT c FROM Cliente c WHERE c.razaoSocial = :razaoSocial"),
               @NamedQuery(name = "Cliente.findByCgc", query = "SELECT c FROM Cliente c WHERE c.cgc = :cgc")})
public class ClientePessoaJuridica extends Cliente {
    private static final long serialVersionUID = 1L;


    @Column(name="RAZAO_SOCIAL")
    private String razaoSocial;

    @Column(name="CGC", length=11, nullable=true, unique=false)
    private String cgc;

    @Override
    public String toString() {
        return "documenteditor.entidade.model.ClientePessoaJuridica[id=" + getIdCliente() + "]";
    }

    public String getCgc() {
        return cgc;
    }

    public void setCgc(String cgc) {
        this.cgc = cgc;
    }

    public String getRazaoSocial() {
        return razaoSocial;
    }

    public void setRazaoSocial(String razaoSocial) {
        this.razaoSocial = razaoSocial;
    }
    
}
